import request from '@/utils/request'

export function queryUmsAdminList(params) {
    return request({
      url:'webApi/admin/admin/list',
      method:'get',
      params:params
    })
}

export function queryUmsAdminRoleList(adminId) {
    return request({
      url:'webApi/admin/admin/role/'+adminId,
      method:'get'
    })
}

export function updateUmsAdminRoleList(params) {
    return request({
        url:'webApi/admin/admin/update',
        method:'post',
        params:params
    })
}


export function createUmsAdmin(data) {
    return request({
        url:'webApi/admin/admin/add',
        method:'post',
        data:data
    })
}

export function updateUmsAdmin(id, data) {
    return request({
        url:'webApi/admin/admin/update/'+id,
        method:'post',
        data:data
    })
}

export function deleteUmsAdmin(id) {
    return request({
        url:'webApi/admin/admin/delete/' + id,
        method:'delete',
    })   
}